import request from '@/utils/request'
export default {

  /** ************************************************ 主表 **************************/
  // 新增产品规范基本信息
  create: data => {
    return request({
      url: `/productSpecification/create`,
      method: 'post',
      data
    })
  },
  // 分页条件查询
  getList: data => {
    return request({
      url: `/productSpecification/findAll`,
      method: 'post',
      data
    })
  },
  // 修改产品规范基本信息
  modify: data => {
    return request({
      url: `/productSpecification/update`,
      method: 'post',
      data
    })
  },
  // 批量删除
  mulDelete: data => {
    return request({
      url: `/productSpecification/deleteBatch`,
      method: 'delete',
      data
    })
  },

  /** ************************************************从表 产品标准  **************************/

  // 新增产品规范标准叙述
  createDesc: data => {
    return request({
      url: `/productSpecificationDesc/create`,
      method: 'post',
      data
    })
  },
  // 分页条件查询
  getDescList: data => {
    return request({
      url: `/productSpecificationDesc/findAll`,
      method: 'post',
      data
    })
  },
  // 修改产品规范基本信息
  modifyDesc: data => {
    return request({
      url: `/productSpecificationDesc/update`,
      method: 'post',
      data
    })
  },
  // 批量删除
  mulDeleteDesc: data => {
    return request({
      url: `/productSpecificationDesc/deleteBatch`,
      method: 'delete',
      data
    })
  },

  /** ************************************************从表 产品用途  **************************/
  createUsage: data => {
    return request({
      url: `/productSpecificationUsageDesc/create`,
      method: 'post',
      data
    })
  },
  // 分页条件查询
  getUsageList: data => {
    return request({
      url: `/productSpecificationUsageDesc/findAll`,
      method: 'post',
      data
    })
  },
  // 修改产品规范基本信息
  modifyUsage: data => {
    return request({
      url: `/productSpecificationUsageDesc/update`,
      method: 'post',
      data
    })
  },
  // 批量删除
  mulDeleteUsage: data => {
    return request({
      url: `/productSpecificationUsageDesc/deleteBatch`,
      method: 'delete',
      data
    })
  }
}
